<?php


namespace App\Models\MainDB;

use Illuminate\Database\Eloquent\Model;

class RewardDetail extends Model
{
    protected $table = 'ln_reward_detail';     //数据库内完整表名

    protected $primaryKey = 'id';    //主键名

    protected $fillable = [
        'id',                 // 主键id
        'reward_id',         //  道具盒子ID
        'item_id',         //道具Id
        'number',            //数量
        'weight',              //权重
        'add_time',
        'type',
    ];
    public $timestamps = false;

    public function reward_item() {
        return $this->hasOne('App\Models\MainDB\RewardItem', 'id', 'item_id');
    }
}
